The present invention relates to tone generation methods for generating tones by running predetermined software on arithmetic processing apparatus.
Tone generation methods have been known which are designed to generate tones by running predetermined software on general-purpose arithmetic processing apparatus such as a CPU. These tone generation schemes are commonly called xe2x80x9csoftware tone generatorsxe2x80x9d. In the software tone generators, a tone generation program is executed at predetermined time intervals to generate tones for a plurality of channels based on given tone control data.
Conventional real-time systems implementing the software tone generators, however, would often present the problem that a generated tone is undesirably broken or noise is produced when waveform formation has been disabled or prevented, for example, due to excessively-increased loads on the arithmetic processor.
Further, in a situation where performance data can not be processed at generation timing or input timing of the data due to excessively-increased loads on the arithmetic processor or the like, the performance data would be left unprocessed at all or, if processed later, unnatural tone control would result.
In view of the foregoing, it is an object of the present invention to provide a tone generation method and apparatus which can reliably avoid an undesired break in a waveform output or noise production even when waveform formation has been disabled or prevented due to excessively-increased loads on a processor or other reason.
In order to accomplish the above-mentioned object, the present invention provides a tone generation method for implementation by use of an apparatus including a processor that executes software, a storage section storing waveform generation software to be executed by the processor, and a buffer storage section that stores waveform data generated by execution of the waveform generation software, which comprises: a step of receiving a tone generation instruction; a step of causing the processor to execute the waveform generation software on the basis of the received tone generation instruction, to thereby not only generate and output waveform data but also previously generate waveform data to be output later than a current time point; a step of storing, into the buffer storage section, the waveform data generated previously via the step of causing; a step of, when there has occurred a situation that disables or prevents waveform generation, outputting the previously-generated waveform data currently stored in the buffer storage section; a step of waiting execution of the tone generation instruction, when there has occurred a situation that disables or prevents previous generation of waveform data based on the tone generation instruction; and a step of generating waveform data based on the tone generation instruction waited by the step of waiting, when the generation of waveform data based on the tone generation instruction becomes possible later.
The present invention also provides a tone generation method for implementation by use of an apparatus including a processor that executes software, a storage section storing waveform generation software to be executed by the processor, and a buffer storage section that stores waveform data generated by execution of the waveform generation software, which comprises: a step of receiving a tone generation instruction; a step of causing the processor to execute the waveform generation software on the basis of the received tone generation instruction, to thereby not only generate and output waveform data but also previously generate waveform data to be output later than a current time point; a step of storing, into the buffer storage section, the waveform data generated previously via the step of causing; and a step of generating waveform data for current and subsequent time points on the basis of the received tone generation instruction and adding the generated waveform data for the current and subsequent time points to the waveform data generated previously via the step of causing and stored in the buffer storage section.
According to another aspect of the present invention, there is provided a tone generation method for implementation by use of an apparatus including a processor that executes software, a storage section storing waveform generation software to be executed by the processor, and a buffer storage section that stores waveform data generated by execution of the waveform generation software, which comprises: a step of receiving a tone generation instruction; a step of causing the processor to execute the waveform generation software on the basis of the received tone generation instruction, thereby generating waveform data in a plurality of channels, and mixing the waveform data, generated in the plurality of channels, on a track-by-track basis to thereby output the mixed waveform data for each of the tracks; a step of previously generating waveform data for a plurality of channels to be output later than a current time point and mixing the waveform data, previously generated in the plurality of channels, on a track-by-track basis to thereby store, into the buffer storage section, the mixed waveform data for each of the tracks; and a step of, when there has occurred a situation that prevents waveform generation, outputting the previously-generated waveform data currently stored in the buffer storage section.
The inventive tone generation method may further comprise a step of receiving track control data so that the waveform data for each of the tracks stored in the buffer storage section are controlled on the basis of the track control data.
The step of previously generating waveform data may previously generate the waveform data on the basis of a previously-received tone generation start instruction.
Further, the step of previously generating waveform data may previously generate the waveform data on the basis of musical composition data to be automatically performed.
Furthermore, in the tone generation based on the waveform generation software, a current time and a tone-generation starting time may be compared so that waveform data starting with an attack portion of a tone are generated when a time delay of the current time from the tone-generation starting time is smaller than a predetermined value, but waveform data starting with a sustain portion of the tone are generated when the time delay of the current time from the tone-generation starting time is greater than a predetermined value.
The present invention may be constructed and implemented not only as the method invention as discussed above but also as an apparatus invention. Also, the present invention may be arranged and implemented as a software program for execution by a processor such as a computer or DSP, as well as a storage medium storing such a program. Further, the processor used in the present invention may comprise a dedicated processor with dedicated logic built in hardware, not to mention a computer or other general-purpose type processor capable of running a desired software program.
While the embodiments to be described herein represent the preferred form of the present invention, it is to be understood that various modifications will occur to those skilled in the art without departing from the spirit of the invention. The scope of the present invention is therefore to be determined solely by the appended claims.